<template>
  <div>
    <p>{{msg}}</p>
    <button @click="reverse">翻转</button>
  </div>
</template>

<script>
export default {
  data () {
    return {
      msg: 'hello,word'
    }
  },

  created () {

  },

  methods: {
    reverse(){
        // console.log(this.msg.split('').reverse().join());
        this.msg = this.msg.split('').reverse().join('')
    }
  }
}
</script>

<style scoped lang='less'>

</style>
